<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean" %>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html" %>
<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic" %>
<%@ taglib uri="http://struts.apache.org/tags-tiles" prefix="tiles" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
		<title>HQL Editor</title>
		<style type="text/css">
			body, td {
				font-family: Arial;
				font-size: 10pt;
			}
		</style>
	</head>
<body>
<form action="../Hql/ExecuteHQL.do" method="POST">
	<table border="0">
		<tr>
			<td><a href="../Hql/PrepareExecuteHQL.do">HQL</a>:</td>
			<td><textarea name="hql" rows="10" cols="60" wrap="virtual"><logic:present name="hql"><bean:write name="hql"/></logic:present></textarea>
			</td>
		</tr>
		<tr>
			<td></td>
			<td align="center"><br><input type="submit" name="submit" value="   Executar   "/></td>
		</tr>
	</table>

	<logic:present name="list">
		<logic:notEmpty name="list">
			<logic:iterate name="list" id="dto">
				<bean:write name="dto" filter="false"/>
			</logic:iterate>
		</logic:notEmpty>
		<logic:empty name="list">
			Nenhum DTO retornado!
		</logic:empty>
	</logic:present>

</form>
</body>
</html>